<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="g" uri="/WEB-INF/tag/guan.tld"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<style>
body {
	margin: 0;
	font-size: 14px;
}

div.helpTitle {
	margin-bottom: 20px
}

div.helpTitle h1 {
	color: #F60;
}

table tr td {
	text-align: center
}

table.customerOrderTable {
	
}

table.customerOrderTable thead tr th {
	color: #333;
	font-weight: bold;
	background: #D9E8F5;
	background-color: #E2F2FF;
	text-align: center;
	height: 40px;
	border-top: 3px solid #A7CBFF;
	border-bottom: 1px solid #A7CBFF;
}

table.customerOrderTable tbody tr td {
	padding: 5px;
	text-align: center;
	border-top: 1px solid #D1EBFF;
	border-bottom: 1px solid #D1EBFF;
}

div.pagelist {
	float: right;
	margin: 20px 20px 0 0
}

.pagelist {
	padding: 10px
}

.pagelist a {
	overflow: hidden;
	display: inline;
	padding: 4px;
	text-decoration: none;
	color: #333;
	border: 1px solid #ebebeb;
}

.pagelist a:hover,.pagelist strong {
	border: 1px solid #ffd375;
	color: #f26101;
	padding: 4px;
}

a.indexPage {
	
}

a.endPage {
	
}
</style>


</head>
<body>
	<div class="helpTitle">
		<h1>订单管理</h1>
	</div>
	<div>
		<table cellspacing="0" cellpadding="0" class="customerOrderTable"
			style="width: 900px">
			<thead>
				<tr>
					<th>编号</th>
					<th>订单号</th>
					<th>时间</th>
					<th>金额</th>
					<th>状态</th>
					<th>操作</th>
				</tr>
			</thead>
			<tbody>
				<s:iterator value="page.list" status="rowstatus">
					<tr>
						<td><s:property
								value="%{page.pageSize*page.currentPageNum+#rowstatus.index+1}" />
						</td>
						<td><s:a action="customer!viewOrder" namespace="/web">
								<s:param name="order.id" value="id"></s:param>
								<s:param name="page.currentPageNum" value="page.currentPageNum"></s:param>
								<s:property value="serialNum" />
							</s:a></td>
						<td><s:date name="createTime" format="yyyy-MM-dd hh:ss" />
						</td>
						<td><s:property value="cost" />
						</td>
						<td><s:property value="state.value" />
						</td>
						<td class=""><s:if test="%{state.key=='CREATE'}">
								<font style="color: red">尚未发出，请等待!</font>
							</s:if> <s:elseif test="%{state.key=='SEND'}">
							已发出，<font style="color: red"> <s:a
										action="customer!viewOrder" namespace="/web">
										<s:param name="order.id" value="id"></s:param>
										<s:param name="page.currentPageNum"
											value="page.currentPageNum"></s:param>
							请查看并确认
						</s:a>
							</s:elseif> <s:elseif test="%{state.key=='SUCCESS'}">
								<font style="color: blue">订单已成功</font>
								<!--<s:a action="customer" namespace="/web" method="viewOrder">评论</s:a>-->
							</s:elseif> 
							
						</td>
					</tr>
				</s:iterator>
			</tbody>
		</table>

		<s:url action="customer!listOrders" namespace="/web" var="pageUrlLink"></s:url>
		<g:pages url="%{pageUrlLink}" tpage="%{page.totalPageNum}"
			cpage="%{page.currentPageNum}" />
	</div>
</body>
</html>